package com.usian.pojo;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;
import java.util.Date;

public class Product implements Serializable {
    @TableId(value = "id",type = IdType.AUTO)
    private Integer id;

    private String name;

    private Integer jg;

    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private Date birthday;

    private Integer status;


    private Integer sku;

    public Integer getSku() {
        return sku;
    }

    public void setSku(Integer sku) {
        this.sku = sku;
    }

    public Integer getStatus() {
        return status;
    }

    public void setStatus(Integer status) {
        this.status = status;
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public Integer getJg() {
        return jg;
    }

    public void setJg(Integer jg) {
        this.jg = jg;
    }

    public Date getBirthday() {
        return birthday;
    }


    @Override
    public String toString() {
        return
                "商品名称" + name + '\n' +
                "价格" + jg + '\n' +
                "日期" + birthday + '\n' +
                "数量" + sku ;
    }

    public void setBirthday(Date birthday) {
        this.birthday = birthday;
    }
}
